package com.yycx.module.bus.provider.handler.haiying.tasktodo.saleman;

import com.yycx.bpm.provider.handler.TaskCompleteHandler;
import com.yycx.bpm.provider.model.TaskRequest;
import com.yycx.common.security.OpenUser;
import com.yycx.module.bus.provider.service.hy.HyOrderService;
import com.yycx.module.bus.provider.service.hy.HyRemoteOrderService;
import com.yycx.module.system.provider.service.SysCompanyService;
import com.yycx.msg.provider.websocket.WebSocketServerEndpoint;
import org.flowable.engine.runtime.ProcessInstance;
import org.flowable.task.api.Task;
import org.springframework.stereotype.Component;

import javax.annotation.Resource;
import java.util.HashMap;
import java.util.Map;

/**
 * 获取任务表单数据
 *
 * @author zyf
 */
@Component
public class SaleManDataHandler implements TaskCompleteHandler {


    /**
     * 是否同步审批信息
     */
    private static final boolean sync = false;


    @Override
    public Map<String, Object> initTaskData(ProcessInstance processInstance, Task task, Map<String, Object> variables) {
        Map<String, Object> ret = new HashMap<>(5);
        String businessKey = processInstance.getBusinessKey();

        return ret;
    }

    /**
     * 表单提交后业务处理
     *
     * @param taskRequest
     * @param processInstance
     * @param task
     * @param completeVariables
     */
    @Override
    public void completeAfter(TaskRequest taskRequest, ProcessInstance processInstance, Task task, Map<String, Object> completeVariables, OpenUser user) {

    }

}
